//
//  Input_GlobalKey_Cell.m
//  百车易车险
//
//  Created bychenxu on 14-8-7.
//  Copyright (c) 2014年 chenxu. All rights reserved.
//

#import "LeftImage_RightButton_Cell.h"

@implementation LeftImage_RightButton_Cell

- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        // Initialization code
    }
    return self;
}

- (void)awakeFromNib
{
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated
{
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (IBAction)clicked:(id)sender {
    if (self.buttonClicked) {
        self.buttonClicked();
    }
}

- (void)configWithImgName:(NSString *)imgStr andValue:(NSString *)valueStr andButtonImgName:(NSString *)name{
    self.imageView.image = [UIImage imageNamed:imgStr];
    self.label.text = valueStr;
    [self.button setBackgroundImage:[UIImage imageNamed:name] forState:UIControlStateNormal];
}



#pragma mark - UIView
- (void)layoutSubviews {
    [super layoutSubviews];
    self.backgroundColor = [UIColor whiteColor];

//    self.backgroundView = nil;
//    self.backgroundColor = [UIColor clearColor];
//    self.contentView.frame = CGRectMake(kPaddingLeftWidth, 0, kScreen_Width - 2*kPaddingLeftWidth, self.contentView.frame.size.height);
//    
//    self.contentView.layer.borderWidth = 0.5;
//    self.contentView.layer.cornerRadius = kCornerRadius;
//    self.contentView.layer.masksToBounds = YES;
}


@end
